#include <stdio.h>
#define N 100

int main () 
{
	int sto[N][N];
	int num;
	
	scanf ("%d",&num);
	
	int i,j;
	for ( i=0 ; i<num; i++) {
		sto[i][i] = 1;
		sto[i][0] = 1;
	}

	for ( i=2; i<num; i++) {
		for ( j=1; j<=i; j++) {
			sto[i][j] = sto[i-1][j] + sto[i-1][j-1];
		}
	}
	
	for ( i=0; i<num; i++) {
		for ( j=0; j<=i; j++) {
			printf("%d ",sto[i][j]);
		}
		printf("\n");
	}
	
	return 0;
}